package com.study.manage.domain;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import com.study.manage.domain.enumm.TaskState;
import com.study.manage.domain.enumm.TaskType;
import com.study.manage.domain.enumm.UserType;
import com.study.manage.domain.enumm.YesNoState;

@Entity
@Table(name = "yy_task")
public class Task extends AbstractEntity {

    private static final long serialVersionUID = -5013690784447412826L;

    public String name;
    public String bannerUrl;
    public Integer joinNumber;
    public Integer awardNumber;
    @Column(name = "typee")
    public TaskType type = TaskType.Default;
    public UserType userType = UserType.TEACHER;
    public TaskState state = TaskState.Release;
    public YesNoState ifAllJoin = YesNoState.NO;
    public String contentJson;
    public String descript;
    public Date beginAt;
    public Date endAt;

    public Task() {}

    public Task(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getJoinNumber() {
        return joinNumber;
    }

    public void setJoinNumber(Integer joinNumber) {
        this.joinNumber = joinNumber;
    }

    public Integer getAwardNumber() {
        return awardNumber;
    }

    public void setAwardNumber(Integer awardNumber) {
        this.awardNumber = awardNumber;
    }

    public TaskType getType() {
        return type;
    }

    public void setType(TaskType type) {
        this.type = type;
    }

    public UserType getUserType() {
        return userType;
    }

    public void setUserType(UserType userType) {
        this.userType = userType;
    }

    public TaskState getState() {
        return state;
    }

    public void setState(TaskState state) {
        this.state = state;
    }

    public YesNoState getIfAllJoin() {
        return ifAllJoin;
    }

    public void setIfAllJoin(YesNoState ifAllJoin) {
        this.ifAllJoin = ifAllJoin;
    }

    public String getContentJson() {
        return contentJson;
    }

    public void setContentJson(String contentJson) {
        this.contentJson = contentJson;
    }

    public String getDescript() {
        return descript;
    }

    public void setDescript(String descript) {
        this.descript = descript;
    }

    public Date getBeginAt() {
        return beginAt;
    }

    public void setBeginAt(Date beginAt) {
        this.beginAt = beginAt;
    }

    public Date getEndAt() {
        return endAt;
    }

    public void setEndAt(Date endAt) {
        this.endAt = endAt;
    }

    public String getBannerUrl() {
        return bannerUrl;
    }

    public void setBannerUrl(String bannerUrl) {
        this.bannerUrl = bannerUrl;
    }


}
